package com.itheima.test;

import java.time.Instant;
import java.time.ZoneId;
import java.time.ZonedDateTime;
import java.time.format.DateTimeFormatter;

public class Test01 {
    public static class Test {
        public static void main(String[] args) {

            ZonedDateTime zonedDateTime = Instant.now().atZone(ZoneId.of("Asia/Shanghai"));

            DateTimeFormatter dateTimeFormatter = DateTimeFormatter.ofPattern("" +
                    "yyyy-MM-dd HH:mm:ss EE a");

            System.out.println(dateTimeFormatter.format(zonedDateTime));


        }
    }
}
